my school quarter just started, so this puzzle doesn't get to be optimized beyond primaries, but at least I'm 100% certain that 4 is the optimal here

edit: just a bit of optimization